/*
 * Flowable CMMN REST API
 * # flowable / flowəb(ə)l /    - a compact and highly efficient workflow and Business Process Management (BPM) platform for developers, system admins and business users.  - a lightning fast, tried and tested BPMN 2 process engine written in Java. It is Apache 2.0 licensed open source, with a committed community.  - can run embedded in a Java application, or as a service on a server, a cluster, and in the cloud. It integrates perfectly with Spring. With a rich Java and REST API, it is the ideal engine for orchestrating human or system activities.
 *
 * OpenAPI spec version: v1
 *
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */


package com.ibm.risk.irmp.workflow.client.flowable.model;

import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;
import java.time.OffsetDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * PlanItemInstanceQueryRequest
 */

public class PlanItemInstanceQueryRequest {
  @JsonProperty("start")
  private Integer start = null;

  @JsonProperty("size")
  private Integer size = null;

  @JsonProperty("sort")
  private String sort = null;

  @JsonProperty("order")
  private String order = null;

  @JsonProperty("id")
  private String id = null;

  @JsonProperty("elementId")
  private String elementId = null;

  @JsonProperty("name")
  private String name = null;

  @JsonProperty("caseInstanceId")
  private String caseInstanceId = null;

  @JsonProperty("caseDefinitionId")
  private String caseDefinitionId = null;

  @JsonProperty("stageInstanceId")
  private String stageInstanceId = null;

  @JsonProperty("planItemDefinitionId")
  private String planItemDefinitionId = null;

  @JsonProperty("planItemDefinitionType")
  private String planItemDefinitionType = null;

  @JsonProperty("planItemDefinitionTypes")
  private List<String> planItemDefinitionTypes = null;

  @JsonProperty("state")
  private String state = null;

  @JsonProperty("createdBefore")
  private OffsetDateTime createdBefore = null;

  @JsonProperty("createdAfter")
  private OffsetDateTime createdAfter = null;

  @JsonProperty("startUserId")
  private String startUserId = null;

  @JsonProperty("referenceId")
  private String referenceId = null;

  @JsonProperty("referenceType")
  private String referenceType = null;

  @JsonProperty("variables")
  private List<QueryVariable> variables = null;

  @JsonProperty("caseInstanceVariables")
  private List<QueryVariable> caseInstanceVariables = null;

  @JsonProperty("tenantId")
  private String tenantId = null;

  @JsonProperty("withoutTenantId")
  private Boolean withoutTenantId = null;

  public PlanItemInstanceQueryRequest start(Integer start) {
    this.start = start;
    return this;
  }

   /**
   * Get start
   * @return start
  **/
  @ApiModelProperty(value = "")
  public Integer getStart() {
    return start;
  }

  public void setStart(Integer start) {
    this.start = start;
  }

  public PlanItemInstanceQueryRequest size(Integer size) {
    this.size = size;
    return this;
  }

   /**
   * Get size
   * @return size
  **/
  @ApiModelProperty(value = "")
  public Integer getSize() {
    return size;
  }

  public void setSize(Integer size) {
    this.size = size;
  }

  public PlanItemInstanceQueryRequest sort(String sort) {
    this.sort = sort;
    return this;
  }

   /**
   * Get sort
   * @return sort
  **/
  @ApiModelProperty(value = "")
  public String getSort() {
    return sort;
  }

  public void setSort(String sort) {
    this.sort = sort;
  }

  public PlanItemInstanceQueryRequest order(String order) {
    this.order = order;
    return this;
  }

   /**
   * Get order
   * @return order
  **/
  @ApiModelProperty(value = "")
  public String getOrder() {
    return order;
  }

  public void setOrder(String order) {
    this.order = order;
  }

  public PlanItemInstanceQueryRequest id(String id) {
    this.id = id;
    return this;
  }

   /**
   * Get id
   * @return id
  **/
  @ApiModelProperty(value = "")
  public String getId() {
    return id;
  }

  public void setId(String id) {
    this.id = id;
  }

  public PlanItemInstanceQueryRequest elementId(String elementId) {
    this.elementId = elementId;
    return this;
  }

   /**
   * Get elementId
   * @return elementId
  **/
  @ApiModelProperty(value = "")
  public String getElementId() {
    return elementId;
  }

  public void setElementId(String elementId) {
    this.elementId = elementId;
  }

  public PlanItemInstanceQueryRequest name(String name) {
    this.name = name;
    return this;
  }

   /**
   * Get name
   * @return name
  **/
  @ApiModelProperty(value = "")
  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public PlanItemInstanceQueryRequest caseInstanceId(String caseInstanceId) {
    this.caseInstanceId = caseInstanceId;
    return this;
  }

   /**
   * Get caseInstanceId
   * @return caseInstanceId
  **/
  @ApiModelProperty(value = "")
  public String getCaseInstanceId() {
    return caseInstanceId;
  }

  public void setCaseInstanceId(String caseInstanceId) {
    this.caseInstanceId = caseInstanceId;
  }

  public PlanItemInstanceQueryRequest caseDefinitionId(String caseDefinitionId) {
    this.caseDefinitionId = caseDefinitionId;
    return this;
  }

   /**
   * Get caseDefinitionId
   * @return caseDefinitionId
  **/
  @ApiModelProperty(value = "")
  public String getCaseDefinitionId() {
    return caseDefinitionId;
  }

  public void setCaseDefinitionId(String caseDefinitionId) {
    this.caseDefinitionId = caseDefinitionId;
  }

  public PlanItemInstanceQueryRequest stageInstanceId(String stageInstanceId) {
    this.stageInstanceId = stageInstanceId;
    return this;
  }

   /**
   * Get stageInstanceId
   * @return stageInstanceId
  **/
  @ApiModelProperty(value = "")
  public String getStageInstanceId() {
    return stageInstanceId;
  }

  public void setStageInstanceId(String stageInstanceId) {
    this.stageInstanceId = stageInstanceId;
  }

  public PlanItemInstanceQueryRequest planItemDefinitionId(String planItemDefinitionId) {
    this.planItemDefinitionId = planItemDefinitionId;
    return this;
  }

   /**
   * Get planItemDefinitionId
   * @return planItemDefinitionId
  **/
  @ApiModelProperty(value = "")
  public String getPlanItemDefinitionId() {
    return planItemDefinitionId;
  }

  public void setPlanItemDefinitionId(String planItemDefinitionId) {
    this.planItemDefinitionId = planItemDefinitionId;
  }

  public PlanItemInstanceQueryRequest planItemDefinitionType(String planItemDefinitionType) {
    this.planItemDefinitionType = planItemDefinitionType;
    return this;
  }

   /**
   * Get planItemDefinitionType
   * @return planItemDefinitionType
  **/
  @ApiModelProperty(value = "")
  public String getPlanItemDefinitionType() {
    return planItemDefinitionType;
  }

  public void setPlanItemDefinitionType(String planItemDefinitionType) {
    this.planItemDefinitionType = planItemDefinitionType;
  }

  public PlanItemInstanceQueryRequest planItemDefinitionTypes(List<String> planItemDefinitionTypes) {
    this.planItemDefinitionTypes = planItemDefinitionTypes;
    return this;
  }

  public PlanItemInstanceQueryRequest addPlanItemDefinitionTypesItem(String planItemDefinitionTypesItem) {
    if (this.planItemDefinitionTypes == null) {
      this.planItemDefinitionTypes = new ArrayList<String>();
    }
    this.planItemDefinitionTypes.add(planItemDefinitionTypesItem);
    return this;
  }

   /**
   * Get planItemDefinitionTypes
   * @return planItemDefinitionTypes
  **/
  @ApiModelProperty(value = "")
  public List<String> getPlanItemDefinitionTypes() {
    return planItemDefinitionTypes;
  }

  public void setPlanItemDefinitionTypes(List<String> planItemDefinitionTypes) {
    this.planItemDefinitionTypes = planItemDefinitionTypes;
  }

  public PlanItemInstanceQueryRequest state(String state) {
    this.state = state;
    return this;
  }

   /**
   * Get state
   * @return state
  **/
  @ApiModelProperty(value = "")
  public String getState() {
    return state;
  }

  public void setState(String state) {
    this.state = state;
  }

  public PlanItemInstanceQueryRequest createdBefore(OffsetDateTime createdBefore) {
    this.createdBefore = createdBefore;
    return this;
  }

   /**
   * Get createdBefore
   * @return createdBefore
  **/
  @ApiModelProperty(value = "")
  public OffsetDateTime getCreatedBefore() {
    return createdBefore;
  }

  public void setCreatedBefore(OffsetDateTime createdBefore) {
    this.createdBefore = createdBefore;
  }

  public PlanItemInstanceQueryRequest createdAfter(OffsetDateTime createdAfter) {
    this.createdAfter = createdAfter;
    return this;
  }

   /**
   * Get createdAfter
   * @return createdAfter
  **/
  @ApiModelProperty(value = "")
  public OffsetDateTime getCreatedAfter() {
    return createdAfter;
  }

  public void setCreatedAfter(OffsetDateTime createdAfter) {
    this.createdAfter = createdAfter;
  }

  public PlanItemInstanceQueryRequest startUserId(String startUserId) {
    this.startUserId = startUserId;
    return this;
  }

   /**
   * Get startUserId
   * @return startUserId
  **/
  @ApiModelProperty(value = "")
  public String getStartUserId() {
    return startUserId;
  }

  public void setStartUserId(String startUserId) {
    this.startUserId = startUserId;
  }

  public PlanItemInstanceQueryRequest referenceId(String referenceId) {
    this.referenceId = referenceId;
    return this;
  }

   /**
   * Get referenceId
   * @return referenceId
  **/
  @ApiModelProperty(value = "")
  public String getReferenceId() {
    return referenceId;
  }

  public void setReferenceId(String referenceId) {
    this.referenceId = referenceId;
  }

  public PlanItemInstanceQueryRequest referenceType(String referenceType) {
    this.referenceType = referenceType;
    return this;
  }

   /**
   * Get referenceType
   * @return referenceType
  **/
  @ApiModelProperty(value = "")
  public String getReferenceType() {
    return referenceType;
  }

  public void setReferenceType(String referenceType) {
    this.referenceType = referenceType;
  }

  public PlanItemInstanceQueryRequest variables(List<QueryVariable> variables) {
    this.variables = variables;
    return this;
  }

  public PlanItemInstanceQueryRequest addVariablesItem(QueryVariable variablesItem) {
    if (this.variables == null) {
      this.variables = new ArrayList<QueryVariable>();
    }
    this.variables.add(variablesItem);
    return this;
  }

   /**
   * Get variables
   * @return variables
  **/
  @ApiModelProperty(value = "")
  public List<QueryVariable> getVariables() {
    return variables;
  }

  public void setVariables(List<QueryVariable> variables) {
    this.variables = variables;
  }

  public PlanItemInstanceQueryRequest caseInstanceVariables(List<QueryVariable> caseInstanceVariables) {
    this.caseInstanceVariables = caseInstanceVariables;
    return this;
  }

  public PlanItemInstanceQueryRequest addCaseInstanceVariablesItem(QueryVariable caseInstanceVariablesItem) {
    if (this.caseInstanceVariables == null) {
      this.caseInstanceVariables = new ArrayList<QueryVariable>();
    }
    this.caseInstanceVariables.add(caseInstanceVariablesItem);
    return this;
  }

   /**
   * Get caseInstanceVariables
   * @return caseInstanceVariables
  **/
  @ApiModelProperty(value = "")
  public List<QueryVariable> getCaseInstanceVariables() {
    return caseInstanceVariables;
  }

  public void setCaseInstanceVariables(List<QueryVariable> caseInstanceVariables) {
    this.caseInstanceVariables = caseInstanceVariables;
  }

  public PlanItemInstanceQueryRequest tenantId(String tenantId) {
    this.tenantId = tenantId;
    return this;
  }

   /**
   * Get tenantId
   * @return tenantId
  **/
  @ApiModelProperty(value = "")
  public String getTenantId() {
    return tenantId;
  }

  public void setTenantId(String tenantId) {
    this.tenantId = tenantId;
  }

  public PlanItemInstanceQueryRequest withoutTenantId(Boolean withoutTenantId) {
    this.withoutTenantId = withoutTenantId;
    return this;
  }

   /**
   * Get withoutTenantId
   * @return withoutTenantId
  **/
  @ApiModelProperty(value = "")
  public Boolean getWithoutTenantId() {
    return withoutTenantId;
  }

  public void setWithoutTenantId(Boolean withoutTenantId) {
    this.withoutTenantId = withoutTenantId;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    PlanItemInstanceQueryRequest planItemInstanceQueryRequest = (PlanItemInstanceQueryRequest) o;
    return Objects.equals(this.start, planItemInstanceQueryRequest.start) &&
        Objects.equals(this.size, planItemInstanceQueryRequest.size) &&
        Objects.equals(this.sort, planItemInstanceQueryRequest.sort) &&
        Objects.equals(this.order, planItemInstanceQueryRequest.order) &&
        Objects.equals(this.id, planItemInstanceQueryRequest.id) &&
        Objects.equals(this.elementId, planItemInstanceQueryRequest.elementId) &&
        Objects.equals(this.name, planItemInstanceQueryRequest.name) &&
        Objects.equals(this.caseInstanceId, planItemInstanceQueryRequest.caseInstanceId) &&
        Objects.equals(this.caseDefinitionId, planItemInstanceQueryRequest.caseDefinitionId) &&
        Objects.equals(this.stageInstanceId, planItemInstanceQueryRequest.stageInstanceId) &&
        Objects.equals(this.planItemDefinitionId, planItemInstanceQueryRequest.planItemDefinitionId) &&
        Objects.equals(this.planItemDefinitionType, planItemInstanceQueryRequest.planItemDefinitionType) &&
        Objects.equals(this.planItemDefinitionTypes, planItemInstanceQueryRequest.planItemDefinitionTypes) &&
        Objects.equals(this.state, planItemInstanceQueryRequest.state) &&
        Objects.equals(this.createdBefore, planItemInstanceQueryRequest.createdBefore) &&
        Objects.equals(this.createdAfter, planItemInstanceQueryRequest.createdAfter) &&
        Objects.equals(this.startUserId, planItemInstanceQueryRequest.startUserId) &&
        Objects.equals(this.referenceId, planItemInstanceQueryRequest.referenceId) &&
        Objects.equals(this.referenceType, planItemInstanceQueryRequest.referenceType) &&
        Objects.equals(this.variables, planItemInstanceQueryRequest.variables) &&
        Objects.equals(this.caseInstanceVariables, planItemInstanceQueryRequest.caseInstanceVariables) &&
        Objects.equals(this.tenantId, planItemInstanceQueryRequest.tenantId) &&
        Objects.equals(this.withoutTenantId, planItemInstanceQueryRequest.withoutTenantId);
  }

  @Override
  public int hashCode() {
    return Objects.hash(start, size, sort, order, id, elementId, name, caseInstanceId, caseDefinitionId, stageInstanceId, planItemDefinitionId, planItemDefinitionType, planItemDefinitionTypes, state, createdBefore, createdAfter, startUserId, referenceId, referenceType, variables, caseInstanceVariables, tenantId, withoutTenantId);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class PlanItemInstanceQueryRequest {\n");

    sb.append("    start: ").append(toIndentedString(start)).append("\n");
    sb.append("    size: ").append(toIndentedString(size)).append("\n");
    sb.append("    sort: ").append(toIndentedString(sort)).append("\n");
    sb.append("    order: ").append(toIndentedString(order)).append("\n");
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    elementId: ").append(toIndentedString(elementId)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    caseInstanceId: ").append(toIndentedString(caseInstanceId)).append("\n");
    sb.append("    caseDefinitionId: ").append(toIndentedString(caseDefinitionId)).append("\n");
    sb.append("    stageInstanceId: ").append(toIndentedString(stageInstanceId)).append("\n");
    sb.append("    planItemDefinitionId: ").append(toIndentedString(planItemDefinitionId)).append("\n");
    sb.append("    planItemDefinitionType: ").append(toIndentedString(planItemDefinitionType)).append("\n");
    sb.append("    planItemDefinitionTypes: ").append(toIndentedString(planItemDefinitionTypes)).append("\n");
    sb.append("    state: ").append(toIndentedString(state)).append("\n");
    sb.append("    createdBefore: ").append(toIndentedString(createdBefore)).append("\n");
    sb.append("    createdAfter: ").append(toIndentedString(createdAfter)).append("\n");
    sb.append("    startUserId: ").append(toIndentedString(startUserId)).append("\n");
    sb.append("    referenceId: ").append(toIndentedString(referenceId)).append("\n");
    sb.append("    referenceType: ").append(toIndentedString(referenceType)).append("\n");
    sb.append("    variables: ").append(toIndentedString(variables)).append("\n");
    sb.append("    caseInstanceVariables: ").append(toIndentedString(caseInstanceVariables)).append("\n");
    sb.append("    tenantId: ").append(toIndentedString(tenantId)).append("\n");
    sb.append("    withoutTenantId: ").append(toIndentedString(withoutTenantId)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}
